package com.opeartion.feign;


import com.opeartion.pojo.CheckStatus;
import com.opeartion.pojo.Store;
import feign.Param;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;
import java.util.Map;


@Service
@FeignClient(value = "PROVIDER",contextId = "STOREClient")
public interface StoreFeign {

    @GetMapping("/store/list")
    List<Store> getAllStore();

    @GetMapping("/store/findCategotry")
    List<Store> findCategotry(@RequestParam("name")String name);

    @GetMapping("/store/findStore")
    List<Store> findStore(@RequestParam("storeld")String storeld) ;

    @PostMapping("/store/updateStoreId")
    void UpdateStoreId(@RequestParam("status")Integer status,@RequestParam("id")Integer id);

    @GetMapping("/store/checkStatus")
     List<Store> checkStatus();

    @PostMapping("/store/findStatus")
     List<Store> findStatus(@Param("checkStatus") CheckStatus checkStatus);
}
